namespace CSharpPro._1014;

public class Student
{
    
    private int id { set; get; } 
    private string name{ set; get; } 
    private int age{ set; get; } 
    private int  grade{ set; get; } 
    
    public Student()
    {
        Console.WriteLine("对象创建成功");
    }
    
    public Student(int id,string name,int age,int grade)
    {
        this.id = id;
        this.name = name;
        this.age = age;
        this.grade = grade;
    }
    public void Show()
    {
        Console.WriteLine("学号：{0}，姓名：{1}，年龄：{2}，年级：{3}",id,name,age,grade);
    }

    public void eat()
    {
        Console.WriteLine(this.name+"正在吃饭");
    }
    
}